package com.woniu.form;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;


import javax.validation.constraints.*;

/**
 * 用户修改购物车的from数据
 */
@Data
@ApiModel("用户添加购物车的from数据")
public class AddShoppingForm {
    /*
    商品id
     */
    @NotNull(message = "商品id不能为空")
    @Min(value = 1,message = "商品id必须是正整数")
    @ApiModelProperty("商品id")
    private Integer goodsId;
    /*
    商品数量
     */
    @NotNull(message = "商品数量不能为空")
    @Min(value = 1,message = "商品数量必须是正整数")
    @ApiModelProperty("商品数量")
    private Integer number;
}
